1. Field of the Invention
The present invention relates to an image forming apparatus, particularly to an image forming apparatus being able to properly detect a loading state of sheets in an output tray to which a sheet on which an image is formed is discharged, and a method of controlling the image forming apparatus.
2. Description of the Related Art
Conventionally, in the image forming apparatus, sometimes the sheet discharged on the output tray is misaligned by the newly-discharged sheet or pushed out from the output tray. In order to avoid such situations, a technique of detecting the loading state of the sheet on the output tray is used to stop the discharge of the sheet onto the output tray when the tray is judged to be fully loaded.
There have been disclosed various techniques concerning the technique of detecting the loading state of the sheet on the output tray to avoid the newly-discharged sheet from pushing out the already stacked sheet.
For example, Japanese Laid-Open Patent Publication No. 10-203724 and No. 2002-012365 disclose a technique of determining how many sheets are stacked on the output tray based on a distance between a ranging sensor fixed to a neighborhood of a discharge port and a point on the sheet located at a top-most position of the output tray.
Japanese Laid-Open Patent Publication No. 2004-115236 discloses a technique of providing a lever abutting on the sheet stacked on the output tray, a light shielding member rotated in conjunction with operation of the lever, and a photosensor. In the technique, the lever and the light shielding member are configured such that rotation angles of the lever and light shielding member are changed according to the number of sheets stacked on the output tray, and a degree of light shielding to the photosensor is changed by the change in rotation angle of the light shielding member. According to the technique, the sheets are stacked such that the light shielding member is rotated to a position where light incident to the photosensor is shielded at least a predetermined degree, which determines that the output tray is fully loaded with the sheets.
However, in the techniques described above, the detection of the number of sheets discharged on the output tray is performed only by detecting the distance between a point on a principal plane (surface in which an image is formed or backside thereof) of the sheet and a specific position (for example, the ranging sensor) in a direction of the principal plane.
Specifically, the number of sheets is detected only at a point X with respect to an output tray 990 as shown in FIG. 14 or at a point Y with respect to the output tray 990 as shown in FIG. 15.
FIGS. 14 and 15 schematically show a neighborhood of the output tray 990 when viewed from a side face. In FIGS. 14 and 15, a sheet P is discharged onto the output tray 990 through a roller 991, and the existence of sheet P is detected at point X or Y located at a level of a distance HA from the output tray 990.
FIG. 14 shows the state sheet P on the output tray 990 is curled such that a central portion of sheet P swells when sheet P is viewed along a discharge direction RP of sheet P. FIG. 15 shows the state sheet P on the output tray 990 is curled such that front-end and rear-end portions of sheet P swell (the central portion is bowed inward) when sheet P is viewed along the discharge direction RP.
In the conventional sheet detection technique, as shown in FIGS. 14 and 15, in the case where a part (the central portion of sheet P in FIG. 14 or the front-end and rear-end portions of sheet P in FIG. 15) of sheet P stacked on the output tray 990 is higher than other portions, when the number of sheets is detected based on the point (point X in FIG. 14 or point Y in FIG. 15) in the portion except for the swell portion, the newly-discharged sheet abuts on the “swell portion” in sheet P already stacked on the output tray 990, which permits sheet P to be pushed out. This is because the newly-discharged sheet collides with the portion located higher than the point (point X or point Y) used to detect sheet P on the output tray 990. That is, an arrow indicating the discharge direction RP intersects a line indicating sheet P on the output tray 990 in FIGS. 14 and 15.